package com.ruoyi.system.api;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import com.ruoyi.common.core.constant.ServiceNameConstants;
import com.ruoyi.common.core.domain.R;
import com.ruoyi.system.api.factory.RemoteDictFallbackFactory;

/**
 * 字典服务
 * 
 * @author ruoyi
 */
@FeignClient(contextId = "remoteDictService", value = ServiceNameConstants.SYSTEM_SERVICE, fallbackFactory = RemoteDictFallbackFactory.class)
public interface RemoteDictService
{
    /**
     * 根据字典类型和值获取字典标签
     *
     * @param dictType 字典类型
     * @param dictValue 字典值
     * @return 结果
     */
    @GetMapping("/dict/data/label/{dictType}/{dictValue}")
    public R<String> getDictLabel(@PathVariable("dictType") String dictType, @PathVariable("dictValue") String dictValue);
}